#TITLE=ASP.NET v1.0
#INFO
ASP/VB.NET Cliptext v1.0 written by Dimitrios Markatos - November, 2001.
Updated April 2003 for C#

#SORT=n

#T==  ASP.NET Objects =
=  ASP.NET Objects =
#T====================
=====================
#T=General tags
General tag

#T=  C# Language
<%@ Page Language="C#" %>

#T=  C# Script tag
<script language="C#" runat="server">
^!

</script>

#T=  VB Language
<%@ Page Language="VB" %>

#T=  VB Script tag
<script Language="VB" runat="server">
^!

</script>

#T=  ASP.Net Tag
<%^!%>

#T=  C# Comment Out
//

#T=  VB Comment Out
'^!

#T=  Comment - .NET
<%-- ^! --%>

#T=  include - .ascx
<%@ Register TagPrefix="^!" TagName="^!" Src="???.ascx" %>

<%-- Format is TagPrefix:TagName id="TagName" --%>
< :^! ID="^!" runat="server" />

#T=  page Output Caching
<%@ OutputCache Duration="^!" VaryByParam="^!"%>

#T=  page Inherits - Code Behind
<%@ Page Inherits="^!" Src="^???.vb" %>

#T=  page Directive - Strict / Explicit / Buffer
<%@ Page Language="VB" Debug="True|False" Strict="True" Explicit="True" Buffer="True"%>

#T=  page.IsPostBack
Page.IsPostBack

#T=  Response Output
<%=^! %>  

#T= ---------------------------
 ---------------------------
#T=System Namespaces
System Namespaces

#T=  Microsoft Data Application Blocks
<%@ Import Namespace="Microsoft.ApplicationBlocks.Data" %>

#T=  Microsoft.Data.SqlXml
<%@ Import Namespace="Microsoft.Data.SqlXml" %>

#T=  System
<%@ Import Namespace="System" %>

#T=  System.Configuration
<%@ Import Namespace="System.Configuration" %>

#T=  System.Data
<%@ Import Namespace="System.Data" %>

#T=  System.Data.OleDB
<%@ Import Namespace="System.Data.OleDB" %>

#T=  System.Data.SqlClient
<%@ Import Namespace="System.Data.SqlClient" %>

#T=  System.Diagnostics - ex. Tracing
<%@ Import Namespace="System.Diagnostics" %>

#T=  System.Drawing
<%@ Import Namespace="System.Drawing" %>

#T=  System.IO - New FSO
<%@ Import Namespace="System.IO" %> 

#T=  System.System.Reflection
<%@ Import Namespace="System.Reflection" %>

#T=  System.Web
<%@ Import Namespace="System.Web" %>

#T=  System.Web.HttpUtility
<%@ Import Namespace="System.Web.HttpUtility" %>

#T=  System.Web.Mail
<%@ Import Namespace="System.Web.Mail" %>

#T=  System.Web.UI.HtmlControls
<%@ Import Namespace="System.Web.UI.HtmlControls" %>

#T=  System.Web.UI - Literal Controls
<%@ Import Namespace="System.Web.UI" %>

#T=  System.Web.UI.WebControls
<%@ Import Namespace="System.Web.UI.WebControls" %>

#T=  System.Xml
<%@ Import Namespace="System.Xml" %>

#T=  System.Xml.Xsl
<%@ Import Namespace="System.Xml.Xsl" %>

#T= ---------------------------
 ---------------------------
#T=Page Functions
Page Functions



#T=  * C# Variables And Methods
 ---------------------------
#T= 
#T=    Variables
string | int ^!;

#T=    private Variables
private 'string | int ^!;

#T=    protected Variables
protected 'string | int ^!;

#T=    public Variables
public 'string | int ^!;

#T=    C# Subroutine
object | string | bool ^! () {


	return ^!;
}

#T=    C# Function
void ^!() {

}

#T= 

#T=  * VB Variables And Methods
 ---------------------------
#T= 
#T=    Dim Variables
Dim ^! As 
'String | Integer

#T=    private Variables
Private ^! As 
'String | Integer

#T=    protected Variables
Protected ^! As 
'String | Integer

#T=    public Variables
Public ^! As 
'String | Integer

#T=    VB Subroutine
Sub (^!)

End Sub

#T=    VB Function
Function (^!) As Object

End Function


#T====================
=====================
#T== Web.Config =
= Web.Config =
#T====================
=====================
#T=Web.Config File
'Save file as web.config
<configuration>

    <!-- store the database connection info here -->
 <appSettings>
     
     'SQL Databases
     <add key="SQL" value="server=(local);uid=sa;pwd=;database=^!;Trusted_Connection=yes;" />

     'Access Databases
    <add key="Access" value="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=--DB File Path--" />

  </appSettings>

  <system.web>

    <pages buffer="^!"
	   enableSessionState="^!" 
    />

    <compilation>
        <assemblies>
            <!--This tells ASP.NET to load all assemblies from /bin-->
            <add assembly="*"/>
        </assemblies>
    </compilation>
  </system.web>

</configuration>

#T=Configuration Call
ConfigurationSettings.AppSettings("^!")

#T====================
=====================
#T== ADO.NET Objects =
= ADO.NET Objects =
#T====================
=====================

#T=  C# DataSet/DataGrid
void DataSet() {

	SqlConnection MyConnection;
	DataSet DS;
	SqlDataAdapter MyCommand;

	String sqlStr = ; //Put SQL Query String Here
	String strConn = ; //Put Connection String Here

	MyConnection = new SqlConnection(strConn);

	MyCommand = new SqlDataAdapter(sqlStr, MyConnection);

	DS = new DataSet();
	MyCommand.Fill(DS, "MyDataGrid"); //Grid Name Goes Here

	MyDataGrid.DataSource = DS;
	MyDataGrid.DataBind();

}

#T=  C# DataReader
void DataReader() {

	String sqlStr = ; //Put SQL Query String Here
	String strConn = ; //Put Connection String Here

	SqlConnection MyConnection = new SqlConnection (strConn);

	MyConnection.Open();

	SqlCommand MyCommand = new SqlCommand(sqlStr, MyConnection);

	SqlDataReader objDataReader = MyCommand.ExecuteReader(CommandBehavior.CloseConnection);

	while (objDataReader.Read()) {
	  Response.Write (objDataReader[1] + "<BR>");
	}

#T=  VB DataSet/DataGrid
Sub DataSet()

	Dim MyConnection As SqlConnection
	Dim DS As DataSet
	Dim MyCommand As SqlDataAdapter

	Dim sqlStr As String = 'Put SQL Query String Here
	Dim strConn As String = 'Put Connection String Here

	MyConnection = New SqlConnection(strConn)

	MyCommand = New SqlDataAdapter(sqlStr, MyConnection)

	DS = new DataSet()
	MyCommand.Fill(DS, "MyDataGrid") 'Grid Name Goes Here

	MyDataGrid.DataSource = DS
	MyDataGrid.DataBind()

End Sub

#T=  VB DataReader
Sub DataReader()

	Dim sqlStr As String = 'Put SQL Query String Here
	Dim strConn As String = 'Put Connection String Here

	Dim MyConnection As New SQLConnection (strConn)

	MyConnection.Open()

	Dim MyCommand As New SQLCommand(sqlStr, MyConnection)

	Dim objDataReader As SQLDataReader 

	objDataReader  = MyCommand.ExecuteReader(CommandBehavior.CloseConnection)

	While objDataReader.Read()
	  Response.Write (objDataReader("^!"))
	End While

End Sub

#T= ---------------------------
 ---------------------------

#T=WebControls
WebControls 

#T=  AdRotator
<asp:AdRotator id="^!" AdvertisementFile="^!" BorderWidth="^!" runat="server" />

#T=  Button
<asp:Button id="^!" Text="^!" onclick="^!" runat="server" />

#T=  Calendar
<asp:Calendar id="^!" onselectionchanged="^!" runat="server" />

#T=  CheckBox
<asp:CheckBox id="^!" Text="^!" runat="server" />

#T=  CheckBoxList
        <asp:CheckBoxList id="^!" runat="server">
            <asp:ListItem>^!</asp:ListItem>
            <asp:ListItem>^!</asp:ListItem>
        </asp:CheckBoxList>

#T=  CustomValidator
    <asp:CustomValidator id="^!" runat="server"
        ControlToValidate="^!"
        OnServerValidate="^!"
        Display="^!" 'Static or Dynamic
        Font-Name="^!" Font-Size="^!">
           'Message goes here
    </asp:CustomValidator>

#T=  DataGrid
      <ASP:DataGrid id="MyDataGrid" runat="server"
        AutoGenerateColumns="True"
        BorderColor="^!"
        BorderWidth="^!"
        CellPadding="^!"
        CellSpacing="^!"
        Font-Name="^!"
        Font-Size="^!"
        HeaderStyle-BackColor="^!"
      />

#T=  DataList
        <asp:DataList id="MyDataList" runat="server"
            BorderColor="^!"
            CellPadding="^!"
            Font-Name="^!"
            Font-Size="^!"
            HeaderStyle-BackColor="^!"
            AlternatingItemStyle-BackColor="^!"
            >
              <HeaderTemplate>
                'Items
              </HeaderTemplate>
              <ItemTemplate>
                <%# DataBinder.Eval(Container.DataItem, "^!") %>
              </ItemTemplate>
        </asp:DataList>

#T=  DropDownList
<asp:DropDownList id="^!" runat="server" />

#T=  Hyperlink
<asp:Hyperlink id="^!" runat="server">
            'Put Text Here
</asp:Hyperlink>

#T=  Image
<asp:Image ID="^!" ImageUrl="^!" AlternateText="^!" runat="server" />

#T=  ImageButton
<asp:ImageButton id="^!"  ImageUrl="^!" BorderWidth="^!" onclick="^!" runat="server" />

#T=  Label
<asp:Label id="^!" Text="^!" Font-Name="^!" Font-Size="^!" Width="^!" BorderStyle="^!" BorderColor="^!" Visible="^!" runat="server"/>

#T=  LinkButton
<asp:LinkButton Text="^!" Font-Name="^!" Font-Size="^!" onclick="^!" runat="server"/>

#T=  ListBox
<asp:ListBox id="^!" Width="^!" runat="server">
  <asp:ListItem>^!</asp:ListItem>
  <asp:ListItem>^!</asp:ListItem>
</asp:ListBox>

#T=  Literal
<asp:Literal id="^!" Text="^!" runat="server"/>

#T=  panel
<asp:Panel id="^!" runat="server" BackColor="^!" Height="^!" Width="^!">
  'Content Goes Here
</asp:Panel>

#T=  placeHolder
<asp:PlaceHolder id="^!" runat="server" />

#T=  RadioButton
<asp:RadioButton id="^!" Text="^!" Checked="^!" GroupName="^!" runat="server" />

#T=  RadioButtonList
<asp:RadioButtonList id="^!" runat="server">
     <asp:ListItem>^!</asp:ListItem>
     <asp:ListItem>^!</asp:ListItem>
</asp:RadioButtonList>

#T=  RegularExpressionValidator
<asp:RegularExpressionValidator id="^!" runat="server"
              ControlToValidate="^!"
              ValidationExpression="^!"
              Display="^!"
              Font-Name="^!" 
              Font-Size="^!">
	'Error Test Message
</asp:RegularExpressionValidator>

#T=  Repeater
<asp:Repeater id="^!" runat="server">

    <HeaderTemplate>

    </HeaderTemplate>

    <ItemTemplate>

    </ItemTemplate>

    <FooterTemplate>

    </FooterTemplate>

</asp:Repeater>

#T=  RequiredFieldValidator
<asp:RequiredFieldValidator id="^!" ControlToValidate="^!" Font-Name="^!" Font-Size="^!" runat="server">
    'Text goes here
</asp:RequiredFieldValidator>

#T=  TextBox
<asp:TextBox id="^!" runat="server"/>

#T=  Xml
<asp:Xml id="^!"
     Document="XmlDocument object to display"
     DocumentContent="String of XML"
     DocumentSource="Path to XML Document"
     Transform="XslTransform object"
     TransformSource="Path to XSL Transform Document"
     runat="server">


#T= ---------------------------
 ---------------------------
#T=Response method
Response method
#T=  Buffer
Response.BufferOutput = ^!
'Value=True or False

#T=  Buffer = True
<%Response.BufferOutput = "True"%>

#T=  Clear
Response.Clear

#T=  End
Response.End

#T=  Flush
Response.Flush

#T=  Redirect
Response.Redirect("^!") 

#T=  Write
Response.Write(^!)

#T=  Write ""
Response.Write("^!")

#T=    + New VB.NET Methods
    + New VB.NET Methods
#T=  Trim$
Trim$(^!)

#T=  String.Compare
String.Compare(-Str1-,-Str2-)

#T= ---------------------------
 ---------------------------

#T=Control structure
Control structure
#T=  if
if (^!)  then
'Asp code goes here
ElseIf (  ) then
'Asp code goes here
Else
'Asp code goes here
End if

#T=  For each
For Each ^! In (   )
'Asp code goes here
Next

#T=  For..next
For (^!) to
'Asp code goes here
Next

#T=  Select..case
Select Case (^!)
Case (  )
'Asp code goes here
Case (  )
'Asp code goes here
Else
'Asp code goes here
ENd Select

#T=  Do..while
Do While (^!)
'Asp code goes here
Loop

#T=  Do..until
Do 
'Asp code goes here
Loop Until (^!)

#T=  While..wend
While (^!)
'Asp code goes here
Wend

#T= ---------------------------
 ---------------------------

#T=Response properties
Response properties

#T=  Cookies
Response.Cookies["^!"].Value=

#T=  CookiesExpire
Response.Cookies["^!"].Expires=" "

#T=  Expires
Response.Cache.SetExpires(DateTime.Now.AddSeconds(0))
'Value=Minutes

#T=  Expires
<%Response.Expires = 0%>

#T=  ExprAbsolute
Response.ExpiresAbsolute =#^!#
'Value=Date or Time

#T=  isConnected
Response.IsClientConnected()

#T= ---------------------------
 ---------------------------
#T=Error properties
Error properties
#T=  Error handling
Try

Catch e As Exception
      
End Try

#T=  Message
e.Message.ToString()

#T=  Number
e.Number

#T=  Source
e.Source.ToString()

#T=  StackTrace
e.StackTrace.ToString()

#T= ---------------------------
 ---------------------------
#T=Request collections
Request collections

#T=  Form
Request.Form(^!)

#T=  Form ("")
Request.Form("^!")

#T=    + Form Loop
For Each ^! in ^! 

Next 

#T=    + FormCount
Request.Form("^!").Count

#T=  QueryString
Request.QueryString("^!")

#T=    + QueryStringCount
Request.QueryString("^!").Count

#T=ServerVariables
ServerVariables
#T=  ALL_HTTP
Request.ServerVariables("ALL_HTTP")

#T=  CONTENT_TYPE
Request.ServerVariables("CONTENT_TYPE")

#T=  CONTENT_LENGTH 
Request.ServerVariables("CONTENT_LENGTH")

#T=  HTTP_USER_AGENT
Request.ServerVariables("HTTP_USER_AGENT")

#T=  REQUEST_METHOD
Request.ServerVariables("REQUEST_METHOD")

#T=  QUERY_STRING
Request.ServerVariables("QUERY_STRING")

#T= ---------------------------
 ---------------------------
#T=Server properties
Server properties
#T=  ScriptTimeout
Server.ScriptTimeout = "^!"
'Value=second

#T=Server method
Server method
#T=  HTMLEncode
Server.HTMLEncode("^!")

#T=  MapPath
Server.MapPath("^!")

#T=  URLEncode
Server.URLEncode("^!")

#T====================
=====================
#T== .NET File Object =
= .NET File Object =
#T====================
=====================

#T=FileSystemObject method
FileSystemObject method

#T=  CreateDirectory
File.CreateDirectory

#T=  FileReader Object
Dim FileReader As StreamReader
FileReader = File.OpenText("^!")

#T=  FileWriter Object
Dim FileWriter As StreamWriter  

#T=  CreateTextFile
FileWriter = File.CreateText(" ^! ")
'Return TextStream object

#T=  DeleteFile
File.Delete(FilePath) 

#T=  FileExists
File.Exists(FilePath)
'File Path

#